Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change VPC CR Conditions #791

Merged
merged 1 commit into from
Oct 10, 2024
Merged

Change VPC CR Conditions #791

merged 1 commit into from
Oct 10, 2024

Conversation

lxiaopei
Copy link
Contributor

@lxiaopei lxiaopei commented Oct 2, 2024

For IPAddressAllocation, SecurityPolicy, StaticRoute, SubnetPort CR, change to use "reason" for simplified message and "message" for details messages. according to https://github.com/kubernetes/apimachinery/blob/d4f471b82f0a17cda946aeba446770563f92114d/pkg/apis/meta/v1/types.go#L1407 Reason : reason contains a programmatic identifier indicating the reason for the condition Message : message is a human readable message indicating details about the transition

timdengyun
timdengyun previously approved these changes Oct 3, 2024
Copy link
Contributor

@timdengyun timdengyun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

yanjunz97
yanjunz97 previously approved these changes Oct 3, 2024
@yanjunz97
Copy link
Contributor

Looks like the UT regarding status update in ipaddressallocation fails

For IPAddressAllocation, SecurityPolicy, StaticRoute, SubnetPort CR,
change to use "reason" for simplified message and "message" for details messages.
according to https://github.com/kubernetes/apimachinery/blob/d4f471b82f0a17cda946aeba446770563f92114d/pkg/apis/meta/v1/types.go#L1407
Reason : reason contains a programmatic identifier indicating the reason for the condition
Message : message is a human readable message indicating details about the transition
@codecov-commenter
Copy link

Codecov Report

Attention: Patch coverage is 42.10526% with 11 lines in your changes missing coverage. Please review.

Project coverage is 48.86%. Comparing base (2183145) to head (f4d9664).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
...ollers/securitypolicy/securitypolicy_controller.go 0.00% 5 Missing ⚠️
...kg/controllers/subnetport/subnetport_controller.go 0.00% 5 Missing ⚠️
pkg/controllers/subnet/subnet_controller.go 0.00% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #791      +/-   ##
==========================================
+ Coverage   48.42%   48.86%   +0.44%     
==========================================
  Files          94       94              
  Lines       11943    11943              
==========================================
+ Hits         5783     5836      +53     
+ Misses       5666     5619      -47     
+ Partials      494      488       -6     
Flag Coverage Δ
unit-tests 48.86% <42.10%> (+0.44%) ⬆️
Files with missing lines Coverage Δ
...ddressallocation/ipaddressallocation_controller.go 80.70% <100.00%> (ø)
.../controllers/staticroute/staticroute_controller.go 77.55% <100.00%> (ø)
pkg/controllers/subnet/subnet_controller.go 9.85% <0.00%> (ø)
...ollers/securitypolicy/securitypolicy_controller.go 50.00% <0.00%> (ø)
...kg/controllers/subnetport/subnetport_controller.go 21.99% <0.00%> (ø)

... and 2 files with indirect coverage changes

@lxiaopei
Copy link
Contributor Author

lxiaopei commented Oct 3, 2024

fixed now. thanks.

Copy link
Contributor

@timdengyun timdengyun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@lxiaopei lxiaopei merged commit 7223696 into main Oct 10, 2024
2 checks passed
@lxiaopei lxiaopei deleted the topic/lxiaopei/condition branch October 10, 2024 04:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants